<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<!DOCTYPE html>
<html>
<head>
<base href="<%=basePath%>">
<title>消费退换申请</title>
<%@include file="../collect/meta.jsp"%>
<script type="text/javascript" charset="utf-8"
	src="${ctx }/calender/WdatePicker.js">
</script>
<script type="text/javascript" src="${ctx}/js/returnTop.js"></script>
<link rel="stylesheet" href="css/radius.css" type="text/css"></link>
</head>
<body lang="zh-cn">
	<div class="wrapper">
		<c:import url="/muser/musertop.jsp"></c:import>
		<div class="main-container" id="main-container">
			<div class="main-container-inner">
				<c:import url="/muser/muserleft.jsp"></c:import>
				<div class="main-content">
					<div class="breadcrumbs" id="breadcrumbs">
						<ul class="breadcrumb">
						<li><i class="icon-home home-icon"></i>退换管理</li><li>消费退换申请</li>					
							</ul>
						<!-- .breadcrumb -->
					</div>
					<div class="page-content">
						<div class="row">
							<div class="col-xs-12">
								<!-- PAGE CONTENT BEGINS -->								
									<form action="bApplication!getByCreateTimeAndMemberId">									
										<input type="text" class="Wdate"
											onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'})"
											style="width:186px;height:30px;" placeholder="开始时间"
											name="beginTime" value="${beginTime }"> <input type="text" class="Wdate"
											onfocus="WdatePicker({dateFmt:'yyyy-MM-dd HH:mm:ss'})"
											style="width:186px;height:30px;" placeholder="结束时间"
											name="endTime" value="${endTime }"> <input type="text" id="mobile"
											name="member.mobile" placeholder="手机号" maxlength="11" value="${ member.mobile}">
										<input type="submit" class="btn btn-primary radius btn-sm" value="搜 索">
										<c:if test="${message==null }"></c:if>
										<c:if test="${message!=null }"><span style="color: red;">${message }</span></c:if>
									</form>
								<br />
								<c:if test="${temp!=''}">
									<form >
										<table class="table table-striped table-bordered table-hover">
											<tr>
												<td><div align="center">会员账号</div></td>
												<td><div align="center">会员姓名</div></td>
												<td><div align="center">消费时间</div></td>
												<td><div align="center">消费金额</div></td>
												<td><div align="center">消费店铺</div></td>
												<td><div align="center">操作人</div></td>
												<td><div align="center">操作</div></td>
											</tr>
											<c:forEach items="${consumeList}" var="listConsume"
												varStatus="status">
												<tr>
													<td><div align="center">${listConsume.member.mobile }</div></td>
													<td><div align="center">${listConsume.memberName }</div></td>
													<td><div align="center">${listConsume.createTime }</div></td>
													<td><div align="center">${listConsume.money }</div></td>
													<td><div align="center">${listConsume.shopName }</div></td>
													<td><div align="center">${listConsume.userName }</div></td>
													<td>
													<div align="center">
														<c:if test="${listConsume.applicationType==1}">您已申请</c:if>
														<c:if test="${listConsume.applicationType!=1}">
															<a class="btn btn-xs btn-primary"href="bApplication!applicationSelect?consume.id=${listConsume.id}">申请退换</a>
														</c:if>
													</div>
													</td>
												</tr>
											</c:forEach>
										</table>
										<table width="100%"  border="0" >
								          <tr bgcolor="#fff0f0">
								            <td width="19%">&nbsp;</td>
								            <td width="13%"><div align="center"><a href="bApplication!getByCreateTimeAndMemberId?index=1&beginTime=${beginTime }&endTime=${endTime }&member.mobile=${member.mobile} ">第一页</a></div></td>
								            <td width="13%"><div align="center"><a href="bApplication!getByCreateTimeAndMemberId?index=${index-1}&beginTime=${beginTime }&endTime=${endTime }&member.mobile=${member.mobile} ">上一页</a></div></td>
								            <td width="10%"><div align="center">${index }</div></td>
								            <td width="13%"><div align="center"><a href="bApplication!getByCreateTimeAndMemberId?index=${index+1}&beginTime=${beginTime }&endTime=${endTime }&member.mobile=${member.mobile} ">下一页</a></div></td>
								            <td width="13%"><div align="center"><a href="bApplication!getByCreateTimeAndMemberId?index=${page }&beginTime=${beginTime }&endTime=${endTime }&member.mobile=${member.mobile} ">最末页</a></div></td>
								            <td width="19%">&nbsp;</td>
								          </tr>
								        </table>
									</form>
								</c:if>
								<!-- PAGE CONTENT ENDS -->
							</div>
							<!-- /.col -->
						</div>
						<!-- /.row -->
					</div>
					<!-- /.page-content -->
				</div>
				<!-- /.main-content -->
			</div>
			<!-- /.main-container-inner -->
			<a href="#" id="btn-scroll-up"
				class="btn-scroll-up btn btn-sm btn-inverse"
				style="position: fixed; bottom: 0;"> <i
				class="icon-double-angle-up icon-only bigger-110"></i>
			</a>
		</div>
		<!-- /.main-container -->
		<div class="push"></div>
	</div>
	<c:import url="/collect/down.jsp"></c:import>

	<script type="text/javascript">
		 $('.mtuihuan > ul').show();
		 $('.mtuihuan > ul > li > a').eq(0).css("color","red"); 
	</script>
</body>
</html>